#ifndef _UTILS_H
#define _UTILS_H

#include <stdint.h>
#include <stdbool.h>


void reverse_bytes(uint8_t* bytes, size_t size);

int read_file(char *filename, unsigned char *buffer, int len);

int write_file(char *filename, unsigned char *buffer, int len);

uint32_t  get_file_length(const char *filename);

bool  file_exist(const char *filename);

int vcpu_reset(void *buf, size_t buf_len,
               char * model_name,
               uint32_t reset_addr, bool reset_data_valid);

void hex_dump(const uint8_t* addr, uint32_t len);

#endif
